{include file="common/header"}
<!-- 我的 -->

<div name="head_img" class="head_imgk">
	<div class="head_img">
		<a href='/meetTWO/public/index/mine/modifyHead?number={$number}'>
			<img src="/meetTWO/public/static/picture/userHeadImg/{$number}/img.png?rand={$rand}" onerror="javascript:this.src='/meetTWO/public/static/picture/defaultHead.jpg';"
			 id="userHead">
		</a>
	</div>
	<div class="message">
		<p>{$user}</p>
		<p>{$number}</p>
	</div>
</div>

<div class="mine_">
	<div class="mine_l">
		<a href="/meetTWO/public/index/Interest/select">
			<i style="background: url(/meetTWO/public/static/index/picture/liuyan.png) no-repeat;"></i>我的兴趣</a>
	</div>
	<div class="mine_l">
		<a id="myPage" href="#">
			<i style="background: url(/meetTWO/public/static/index/picture/hobby.png) no-repeat;"></i>我的帖子</a>
	</div>
	<div class="mine_l">
		<a href="#" id="myCom">
			<i style="background: url(/meetTWO/public/static/index/picture/coment.png) no-repeat;"></i>我的评论</a>
	</div>
</div>

<div class="mine_" id="setup">
	<div class="mine_l">
		<a href="#">
			<i style="background: url(/meetTWO/public/static/index/picture/shezhi.png) no-repeat;"></i>设置</a>
	</div>
</div>

<div class="mine_" id='setout'>
	<div class="mine_l">
		<a href="#">
			<i style="background: url(/meetTWO/public/static/index/picture/exit.png) no-repeat;"></i>注销</a>
	</div>
</div>



<script>
	$('#myPage').click(function () {
		var url = '/meetTwo/public/index/Mine/myPage';
		var id = getCookie('number')
		window.location.href = url + '?id=' + id
		return false;
	})
	$('#myCom').click(function () {
		var id = getCookie('number')
		var url = '/meetTWO/public/index.php/index/mine/commend?id=' + id
		location.href = url
		return false
	})

	function getCookie(name) {
		var strcookie = document.cookie;//获取cookie字符串
		var arrcookie = strcookie.split("; ");//分割
		//遍历匹配
		for (var i = 0; i < arrcookie.length; i++) {
			var arr = arrcookie[i].split("=");
			if (arr[0] == name) {
				return arr[1];
			}
		}
		return "";
	}
	//退出
	$('#setout').click(function (){
		$.cookie('number', null,{path:"/"}); 
		window.location.href = "/meetTWO/public/index.php/index";
	})
	//设置
	$('#setup').click(function(){
		var number = document.cookie.substring(7);
		console.log(number);
		window.location.href = "/meetTWO/public/index/mine/setup?id="+number;
	})
</script>